package com.sky.dto;

import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.sky.annotations.SexDeserializer;
import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Null;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * @author acer
 */
@Data
public class EmployeeDTO implements Serializable {

    private Long id;
    @NotNull
    private String username;
    @NotNull
    private String name;
    @NotNull
    @Size(min = 11, max = 11)
    private String phone;
    @NotNull
//    @JsonDeserialize(using = SexDeserializer.class)
    private String sex;
    @NotNull
    @Size(min = 18, max = 18)
    private String idNumber;

}
